﻿@model MobilesStore.Domain.Entities.Product
<div class="slide-inner">
    @if (Model.ImageData != null)
        { 
            <div class="image">
                <img width="47" height="47" src="@Url.Action("GetImage", "Product", 
                                    new { Model.ProductID })" alt="@Model.ProductName" title="@Model.ProductName" />
            </div>
        }else{
            <div class="image">
                <img width="47" height="47" src="../../Images/image/product/apple_cinema_30-162x162.jpg" alt="@Model.ProductName" title="@Model.ProductName" />
            </div>
        }
    <div class="name">@Html.ActionLink(Model.ProductName, "Detail","Product",new { Model.ProductID },null)</div>
    <div class="price"> @Model.ProductPrice.ToString("c") </div>
    <div class="cart">
              @using (Html.BeginForm("AddToCart", "Cart"))
              {        
                 @Html.HiddenFor(p=>p.ProductID)
                 @Html.Hidden("returnUrl",Request.Url.PathAndQuery)
                <input type="submit" value="+ Add To Cart" class="button"/>
              }
    </div>
    <div class="clear"></div>
</div>

